package com.example.demo.ThreadTest;

/**
 * 线程在Warting上等待
 * @author FF998
 */
public class WaitingState  implements Runnable {
    @Override
    public void run() {
        while (true){
            synchronized (WaitingState.class){
                try {
                    WaitingState.class.wait();
                } catch (InterruptedException e) {
                    e.printStackTrace();
                }
            }
        }
    }
}
